package model;

import java.util.List;
import java.util.NoSuchElementException;

import model.IManufacturingMethod.SubType;
import model.auxillary.DuplicateNameException;

/**
 * Interface for the {@code EBenchmarkProcess} class.
 * @author Oliver Eckstein
 *
 */
public interface IEBenchmarkProcess extends ICalculatableProcess { //#Neu
    
	/**
     * To add new manufacturing methods to this EBenchmark calculation.
     * @param count number of new manufacturing methods.
     * @param type the manufacturing method's type.
     */
    public void addManufacturingMethods(
            int count, IManufacturingMethod.SubType type);
        
    /**
     * To remove a specific number of manufacturing methods from this
     * EBenchmark calculation.
     * @param count number of manufacturing methods to be removed.
     * @param type the type of manufacturing to delete.
     * @throws IllegalArgumentException when more methods should be
     * deleted than available.
     */
    public void removeManufacturingMethods(
            int count, IManufacturingMethod.SubType type)
            throws IllegalArgumentException;
    
    /**
     * To set a new name for an existing manufacturing method.
     * @param manuMethod the manufacturing method whose name gets changed.
     * @param name the new name.
     * @throws IllegalArgumentException when <b>name</b> was empty
     * @throws DuplicateNameException when another manufacturing
     * method in this EBenchmark calculation has the same name as the given
     * <b>name</b>.
     */
    public void setManufacturingMethodName(IManufacturingMethod manuMethod, String name)
            throws IllegalArgumentException,
                DuplicateNameException;
    
    /**
     * To get the identifying keys of all manufacturing methods stored in this
     * {@code EBenchmark}.
     * @return the identifying keys.
     */
    public List<String> getManuMethodKeys();
    
    /**
     * To get the type of a given <b>manufacturing method</b> translated into
     * German.
     * @param ident the manufacturing method's name whose type should be
     * retrieved.
     * @return the manufacturing method's type.
     */
    public String getType(String ident);
    
    /**
     * To get a specific manufacturing method of this EBenchmark.
     * @param ident the identifying key of a manufacturing method.
     * @return the manufacturing method.
     * @throws NoSuchElementException when manufacturing method was not
     * found under given key
     */
    public IManufacturingMethod getManufacturingMethod(String ident)    
            throws NoSuchElementException;
    
    /**
     * To translate a type of <b>ManuMethod</b> into German.
     * Returns {@code null} when <b>type</b> does not exist.
     * @param subType the type to be translated.
     * @return the translated type.
     */
    public String typeToString(SubType subType);
    
    /**
     * To translate a German manufacturing method into a <b>ManuMethod</b>.
     * Returns {@code null} when <b>manuMethod</b> does not exist. 
     * @param manuMethod the manufacturing method to be translated.
     * @return the translated type.
     */
    public SubType stringToType(String manuMethod);
    
    /**
     * To get the manufacturing methods of this EBenchmark calculation.
     * @return the manufacturing methods of this EBenchmark.
     */
    public List<IManufacturingMethod> getManufacturingMethods();
    
    /**
     * To calculate a specific manufacturing method.
     * @param manuMethod the manufacturing method to be calculated.
     */
    public void calculateManuMethod(IManufacturingMethod manuMethod);
    
    /**
     * To get the number of manufacturing methods in this {@code EBenchmark}.
     * @return the number of manufacturing methods.
     */
    public int getCountManuMethod();
    
    /**
     * To get the name of this EBenchmark calculation.
     * @return the name of EBenchmark calculation.
     */
    public String getName();

}
